<script setup>

const columns = [
  {
    title: 'Name',
    dataIndex: 'name',
    key: 'name',
  },
  {
    title: 'Age',
    dataIndex: 'age',
    key: 'age',
  },
  {
    title: 'Address',
    dataIndex: 'address',
    key: 'address',
  },
  {
    title: 'Action',
    key: 'action',
  },
];
const data = [
];
for(let i = 0; i < 100; i++) {
  data.push({
    key: '1',
    name: 'John Brown',
    age: 32,
    address: 'New York No. 1 Lake Park',
  })
}

</script>

<template>
  <body>
  <div>
    <h1>结果信息管理</h1>
    <div style="text-align: left">
      <a-button type="primary" class="button">
        Add
      </a-button>
    </div>
    <a-table class="table" :columns="columns" :data-source="data">
      <template #bodyCell="{ column, record }">
        <template v-if="column.key === 'name'">
          <a>
            {{ record.name }}
          </a>
        </template>
        <template v-else-if="column.key === 'action'">
        <span>
          <a class="ant-dropdown-link">
            Edit
          </a>
          <a>Delete</a>
        </span>
        </template>
      </template>
    </a-table>

  </div>
  </body>
</template>

<style scoped>
.table{
  color: #5C7BD9;
}
</style>